package com.enation.app.javashop.api.client;

import com.enation.app.javashop.model.goods.vo.GoodsQuantityVO;
import com.enation.app.javashop.service.goods.GoodsQuantityManager;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;

import java.util.List;

/**
 * @author fk
 * @version v2.0
 * @Description: 商品库存
 * @date 2018/9/29 9:26
 * @since v7.0.0
 */
@RestController
@RequestMapping("/client/goods")
@ApiIgnore
public class GoodsQuantityClientController {


    @Autowired
    private GoodsQuantityManager goodsQuantityManager;

    @PostMapping(value = "/add-quantity", consumes = "application/json")
    public boolean updateSkuQuantity(@RequestBody List<GoodsQuantityVO> goodsQuantityList) {

        return goodsQuantityManager.updateSkuQuantity(goodsQuantityList);
    }


}
